#include <iostream>
using namespace std;

class Date
{
public:
	Date(int year = 1, int month = 1, int day = 1)
	{
		_year = year;
		_month = month;
		_day = day;
	}

	bool operator<(Date& x);
	bool operator>(Date& x);
	bool operator<=(Date& x);
	bool operator>=(Date& x);
	bool operator==(Date& x);

private:
	int _year;
	int _month;
	int _day;
};

bool Date::operator<(Date& x)
{
	if (_year < x._year)
	{
		return true;
	}
	else if (_year == x._year && _month < x._month)
	{
		return true;
	}
	else if (_year == x._year && _month == x._month && _day < x._day)
	{
		return true;
	}

	return false;
}

bool Date::operator>(Date& x)
{
	return !(*this <= x);
}

bool Date::operator<=(Date& x)
{
	return *this < x || *this == x;
}

bool Date::operator>=(Date& x)
{
	return !(*this < x);
}

bool Date::operator==(Date& x)
{
	return _year == x._year && _month == x._month && _day == x._day;
}

int main()
{
	Date a(2024, 8, 19);
	Date b(2024, 8, 20);

	cout << (a < b) << endl;
	cout << (a > b) << endl;
	cout << (a <= b) << endl;
	cout << (a >= b) << endl;
	cout << (a == b) << endl;

	return 0;
}